package com.jshoperxms.entity;

import javax.persistence.*;

/**
 * Created by sdywcd on 2018/11/26.
 * Des:
 */
@Entity
@Table(name = "sys_msg_rp_t", schema = "jshoperxms", catalog = "")
public class SysMsgRpT {
    private String id;
    private String msgcontentid;
    private long readtime;
    private String senderid;
    private String receiverid;
    private String readstatus;
    private String title;
    private String level;
    private String shotcontent;
    private long createtime;
    private long updatetime;
    private String status;
    private String type;

    @Id
    @Column(name = "ID", nullable = false, length = 25)
    public String getId() {
        return id;
    }

    public void setId(String id) {
        this.id = id;
    }

    @Basic
    @Column(name = "MSGCONTENTID", nullable = false, length = 25)
    public String getMsgcontentid() {
        return msgcontentid;
    }

    public void setMsgcontentid(String msgcontentid) {
        this.msgcontentid = msgcontentid;
    }

    @Basic
    @Column(name = "READTIME", nullable = false)
    public long getReadtime() {
        return readtime;
    }

    public void setReadtime(long readtime) {
        this.readtime = readtime;
    }

    @Basic
    @Column(name = "SENDERID", nullable = false, length = 25)
    public String getSenderid() {
        return senderid;
    }

    public void setSenderid(String senderid) {
        this.senderid = senderid;
    }

    @Basic
    @Column(name = "RECEIVERID", nullable = false, length = 25)
    public String getReceiverid() {
        return receiverid;
    }

    public void setReceiverid(String receiverid) {
        this.receiverid = receiverid;
    }

    @Basic
    @Column(name = "READSTATUS", nullable = false, length = 1)
    public String getReadstatus() {
        return readstatus;
    }

    public void setReadstatus(String readstatus) {
        this.readstatus = readstatus;
    }

    @Basic
    @Column(name = "TITLE", nullable = false, length = 45)
    public String getTitle() {
        return title;
    }

    public void setTitle(String title) {
        this.title = title;
    }

    @Basic
    @Column(name = "LEVEL", nullable = false, length = 45)
    public String getLevel() {
        return level;
    }

    public void setLevel(String level) {
        this.level = level;
    }

    @Basic
    @Column(name = "SHOTCONTENT", nullable = false, length = 2000)
    public String getShotcontent() {
        return shotcontent;
    }

    public void setShotcontent(String shotcontent) {
        this.shotcontent = shotcontent;
    }

    @Basic
    @Column(name = "CREATETIME", nullable = false)
    public long getCreatetime() {
        return createtime;
    }

    public void setCreatetime(long createtime) {
        this.createtime = createtime;
    }

    @Basic
    @Column(name = "UPDATETIME", nullable = false)
    public long getUpdatetime() {
        return updatetime;
    }

    public void setUpdatetime(long updatetime) {
        this.updatetime = updatetime;
    }

    @Basic
    @Column(name = "STATUS", nullable = false, length = 1)
    public String getStatus() {
        return status;
    }

    public void setStatus(String status) {
        this.status = status;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;

        SysMsgRpT sysMsgRpT = (SysMsgRpT) o;

        if (readtime != sysMsgRpT.readtime) return false;
        if (createtime != sysMsgRpT.createtime) return false;
        if (updatetime != sysMsgRpT.updatetime) return false;
        if (id != null ? !id.equals(sysMsgRpT.id) : sysMsgRpT.id != null) return false;
        if (msgcontentid != null ? !msgcontentid.equals(sysMsgRpT.msgcontentid) : sysMsgRpT.msgcontentid != null)
            return false;
        if (senderid != null ? !senderid.equals(sysMsgRpT.senderid) : sysMsgRpT.senderid != null) return false;
        if (receiverid != null ? !receiverid.equals(sysMsgRpT.receiverid) : sysMsgRpT.receiverid != null) return false;
        if (readstatus != null ? !readstatus.equals(sysMsgRpT.readstatus) : sysMsgRpT.readstatus != null) return false;
        if (title != null ? !title.equals(sysMsgRpT.title) : sysMsgRpT.title != null) return false;
        if (level != null ? !level.equals(sysMsgRpT.level) : sysMsgRpT.level != null) return false;
        if (shotcontent != null ? !shotcontent.equals(sysMsgRpT.shotcontent) : sysMsgRpT.shotcontent != null)
            return false;
        if (status != null ? !status.equals(sysMsgRpT.status) : sysMsgRpT.status != null) return false;

        return true;
    }

    @Override
    public int hashCode() {
        int result = id != null ? id.hashCode() : 0;
        result = 31 * result + (msgcontentid != null ? msgcontentid.hashCode() : 0);
        result = 31 * result + (int) (readtime ^ (readtime >>> 32));
        result = 31 * result + (senderid != null ? senderid.hashCode() : 0);
        result = 31 * result + (receiverid != null ? receiverid.hashCode() : 0);
        result = 31 * result + (readstatus != null ? readstatus.hashCode() : 0);
        result = 31 * result + (title != null ? title.hashCode() : 0);
        result = 31 * result + (level != null ? level.hashCode() : 0);
        result = 31 * result + (shotcontent != null ? shotcontent.hashCode() : 0);
        result = 31 * result + (int) (createtime ^ (createtime >>> 32));
        result = 31 * result + (int) (updatetime ^ (updatetime >>> 32));
        result = 31 * result + (status != null ? status.hashCode() : 0);
        return result;
    }

    @Basic
    @Column(name = "TYPE", nullable = false, length = 1)
    public String getType() {
        return type;
    }

    public void setType(String type) {
        this.type = type;
    }
}
